#ifndef PROGRESSWIDGET_H
#define PROGRESSWIDGET_H

#include <QWidget>
#include <QLabel>
#include <QFont>
#include <QTimer>
#include <QDebug>
#include "wiringPi.h"

namespace Ui {
class ProgressWidget;
}

class ProgressWidget : public QWidget
{
    Q_OBJECT

public:
    explicit ProgressWidget(QWidget *parent = 0);
    ~ProgressWidget();
    QLabel *m_bg;
    QTimer *timer;
    int timeCount = 0;
    int check = 0;
    int startcheck = 0;
    QString text0 = "就绪";
    QString text1 = "清洗";
    QString text2 = "去皮";
    QString text3 = "切割";
    QString text4 = "作业完成";
    QString text5 = "运输中";
    QString title1 = "\"果宝特工\"";
    QString title2 = "当前进行:";
    int time1 = 30; //s
    int time2 = 83; //s
    int time3 = 104; //s
    int time4 = 173;
    int time5 = 193;
    int time6 = 234;
    int per;

    void resizeEvent(QResizeEvent *event);
    void SetText(QString &string);
    void SetMission(QString &string, int t);
    //void timeoutslot();
private:
    Ui::ProgressWidget *ui;
private slots:
    void timeoutslot();
};

#endif // PROGRESSWIDGET_H
